package com.xiaobai.zhuangxiuguanjia.model;

import org.json.JSONException;
import org.json.JSONObject;

/**
 * Created by Android Studio
 * Project: ZhuangXiuGuanJia
 * Author: Jack
 * Email: jackfangqi1314@gmail.com/jackfangqi@163.com
 * Date: 2015/6/17
 */
public class AppData {
    private String aid;
    private String appname;
    private String appdesc;
    private String link;
    private String icon;
    private String score;
    private String label;

    public String getAid() {
        return aid;
    }

    public String getAppdesc() {
        return appdesc;
    }

    public String getAppname() {
        return appname;
    }

    public String getIcon() {
        return icon;
    }

    public String getLabel() {
        return label;
    }

    public String getLink() {
        return link;
    }

    public String getScore() {
        return score;
    }

    public void parseJson(JSONObject jsonObject) {
        if (jsonObject != null) {
            try {
                aid = jsonObject.getString("aid");
                appname = jsonObject.getString("appname");
                appdesc = jsonObject.getString("appdesc");
                link = jsonObject.getString("link");
                icon = jsonObject.getString("icon");
                score = jsonObject.getString("score");
                label = jsonObject.getString("label");
            } catch (JSONException e) {
                e.printStackTrace();
            }
        }
    }
}
